1. Field of the Invention
The present invention relates to optimizing the use of memory buffers of a device which communicates via a physical communication link. More specifically, the present invention relates to a method of optimizing the use of memory buffers of the device which communicates via a physical communication link including a plurality of virtual channels while maintaining a sustained bandwidth for communication between the device and another entity.
2. Description of the Related Art
When communication is established on a physical communication link using a communication protocol such as PCI Express (PCIe), the physical communication link may be divided into multiple virtual channels. These virtual channels transmit information between a device and another entity via the physical communication link.
The device which transmits/receives information, via the multiple virtual channels, must assign certain portions of its memory to each virtual channel. These portions of memory are typically identified as memory buffers that are allocated to the virtual channels.
In order to ensure that a certain communication bandwidth can be sustained on the physical communication link, it is necessary for a sufficient number of memory buffers to be assigned (i.e., made available) to each virtual channel.
Quite often, not every virtual channel of the physical communication link is utilized. However, although each virtual channel is not utilized (i.e., active), each virtual channel (including active and inactive virtual channels) continues to have a certain number of memory buffers allocated thereto. This results in a loss of effective bandwidth of the physical communication link.
More specifically, this problem arises because memory buffers are assigned to the virtual channels of the physical communication link before the device which transmits/receives information realizes how many virtual channels are actually active. Thus, memory buffers are inevitably assigned to virtual channels that are inactive. In addition, once the memory buffers are assigned to the inactive virtual channels the memory buffers can not be redistributed. This practice of allocating memory buffers to inactive virtual channels is an inefficient use of the memory buffers of the device because use of the bandwidth of the physical communication link could be more efficient if memory buffers were only utilized by virtual channels that are “active” (e.g., the physical communication link could be more efficient if active virtual channels were allowed to use the memory buffers originally allocated to the inactive virtual channel(s)).
In order to address the above-mentioned problem, a method of optimization, to be executed during the normal use of a physical communication link for conducting communication between a device and another entity, is described below.